def getMenuOption(debug = False):
	if debug:
		print "getMenuOption Function"
	validInput = False
	while not validInput:
		option = raw_input("> ")
		if option == "1":
			validInput = True
		elif option == "2":
			validInput = True 
		elif option == "3":
			validInput = True 
		elif (option.lower() == "exit" or
		      option.lower() == "e" or
		      option.lower() == "x" or
		      option.lower() == "quit" or
		      option.lower() == "q"):
				  validInput = True
				  option = "exit"
	
		else:
			print "Please type one of the things on the menu !!"
	return option
		
def getWord(prompt, debug = False):
	if debug:
		print "getWord Function", prompt
	validInput = False
	while not validInput:
		option = raw_input(prompt)	
		validInput = True
		if option == "":
			print "Please type an actual word??"
			validInput = False
		elif isSwear(option, debug):
			print "Don't be THAT guy."
			validInput = False
	return option

def getNumber(prompt, debug = False):
	if debug:
		print "getWord Function", prompt
	validInput = False
	numbers = "0123456789."
	while not validInput:
		option = raw_input(prompt)	
		validInput = True
		for character in option:
			if not(character in numbers):
				validInput = False
		if not validInput:
			print "Maybe you should actually type something that is a number..."
	return option
		
		
def isSwear(word, debug = False):
	if debug:
		print "isSwear Function", word
	swears = ["poop",
			  "shit",
			  "pee"
			  "piss"
			  "shit"
			  "piss-poor"
			  "bitch"
			  "whore"
			  "slut"
			  "cunt"
			  "fag"
			  "faggot"
			  "motherfucker"
			  "fuck"
			  "fucking"
			  "fucker"
			  "mother fucker"
			  "pisspoor"
			  "piss poor"
			  "son of a bitch"
			  "bastard"
			  "piece of shit"
			  "dick"
			  "pussy"
			  "cock"
			  "hell"
			  "heck"
			  "hecking"
			  "heckie"
			  "fucked"
			  "shitting"
			  "shat"
			  "ass"
			  "asshole"
			  "assbutt"
			  "asshat"
			  "pissfuck"
			  "hoe"
			  "crap"
			  "penis"
			  "vagina"
			  "vajayjay"
			  "vag"
			  "retard"
			  "retarded"
			  "masturbate"
			  "masturbates"
			  "masturbation"
			  "masturbating"
			  "bullshit"
			  ]
	if word.lower() in swears:
		return True
	else:
		return False
